
package com.flowmodule.bean;

import com.companymodule.bean.TbCompany;
import com.companymodule.dao.TbCompanyDAO;
import com.flowmodule.dao.TbFlowDAO;
import com.usersmodule.bean.TbUsers;
import com.usersmodule.dao.TbUsersDAO;

public class TbFlowCompanyMiddle implements java.io.Serializable {

    private int flowCompanyMiddleId;

    private int companyId;
    private TbCompany tbCompany;

    private int flowId;
    private TbFlow tbFlow;

    private int userId;
    private TbUsers tbUsers;

    private String createTime;

    public int getFlowCompanyMiddleId(){
        return flowCompanyMiddleId;
    }

    public void setFlowCompanyMiddleId(int flowCompanyMiddleId){
        this.flowCompanyMiddleId = flowCompanyMiddleId;
    }

    public int getCompanyId(){
        return companyId;
    }

    public void setCompanyId(int companyId){
        this.companyId = companyId;
        this.tbCompany=new TbCompanyDAO().getTbCompanyByCompanyId(companyId);
    }
    
    public TbCompany getTbCompany() {
		return tbCompany;
	}

	public void setTbCompany(TbCompany tbCompany) {
		this.tbCompany = tbCompany;
	}

	public int getFlowId(){
        return flowId;
    }

    public void setFlowId(int flowId){
        this.flowId = flowId;
        this.tbFlow=new TbFlowDAO().getTbFlowByFlowId(flowId);
    }
    
    public TbFlow getTbFlow() {
		return tbFlow;
	}

	public void setTbFlow(TbFlow tbFlow) {
		this.tbFlow = tbFlow;
	}

	public int getUserId(){
        return userId;
    }

    public void setUserId(int userId){
        this.userId = userId;
        this.tbUsers=new TbUsersDAO().getTbUsersByUserId(userId);
    }
    
    public TbUsers getTbUsers() {
		return tbUsers;
	}

	public void setTbUsers(TbUsers tbUsers) {
		this.tbUsers = tbUsers;
	}

	public String getCreateTime(){
        return createTime;
    }

    public void setCreateTime(String createTime){
        this.createTime = createTime;
    }


    public TbFlowCompanyMiddle(){
    }
    public TbFlowCompanyMiddle(int companyId,int flowId,int userId){
        this.companyId = companyId;
        this.flowId = flowId;
        this.userId = userId;
    }
    public TbFlowCompanyMiddle(int FlowCompanyMiddleId,int companyId,int flowId,int userId){
        this.flowCompanyMiddleId=FlowCompanyMiddleId;
    	this.companyId = companyId;
        this.flowId = flowId;
        this.userId = userId;
    }
}

